<template>
  <div>这里是父元素，尝试给slot添加一个click事件监听</div>
  <slot-events @click="handleClick" @custom-event="handleCustomEvent">
    <slot name="referer"></slot>
  </slot-events>
</template>

<script setup lang="ts">
import {SlotEvents} from "../../lib";
const handleClick = () => {
  alert('捕获了slot的点击事件');
};
const handleCustomEvent = () => {
  console.log('捕获了slot的customEvent');
};
</script>

<style scoped>

</style>
